package flc.ast.utils;


import java.util.ArrayList;
import java.util.List;

import flc.ast.bean.SelectFileBean;

public class SendFileManager {
    private static SendFileManager instance;
    private final List<SelectFileBean> selectFileBeanList = new ArrayList<>();

    private SendFileManager() {

    }

    public synchronized static SendFileManager getInstance() {
        if (instance == null) {
            instance = new SendFileManager();
        }
        return instance;
    }

    public List<SelectFileBean> getSelectFileBeans() {
        return selectFileBeanList;
    }

    public void addSelectFile(SelectFileBean selectFileBean) {
        selectFileBeanList.add(selectFileBean);
    }

    public void deleteSelectFile(int position) {
        selectFileBeanList.remove(position);
    }

    public void clearSelectFile() {
        selectFileBeanList.clear();
    }

}